<%if paginator.item_count > 0 %>
<div class="counter">
   Displaying <%= paginator.current.first_item %>
   - <%= paginator.current.last_item %>
   of <%= paginator.item_count %>    

   <!-- no request.query_parameters ?? -->
   <% search_params = request.parameters.delete_if { |key,value| [:action, :controller].include? key} %>

   <%= link_to('&laquo; Previous', search_params.merge({:page => paginator.current.previous}))  + " | " if paginator.current.previous %>
   <%= pagination_links(paginator, :window_size => 4, :params => search_params) %>
   <%= " | " + link_to('Next &raquo;', search_params.merge({:page => paginator.current.next})) if paginator.current.next %>
</div>
<%end%>
